home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part1 / 5368 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.5 KB

  1. Path: news.via.at!usenet
  2. From: helicon@helicon.co.at (helicon)
  3. Newsgroups: comp.lang.pascal.delphi.misc,comp.lang.c++
  4. Subject: Re: Delphi calls to a C++ DLL
  5. Date: 3 Feb 1996 22:09:34 GMT
  6. Organization: helicon software development
  7. Message-ID: <4f0meu$404@newsfeed.via.at>
  8. References: <310FD68B.208B@allaire.com> <4erttn$l9v@newsfeed.via.at> <3112841B.5D2F@allaire.com>
  9. NNTP-Posting-Host: helicon.via.at
  10. Mime-Version: 1.0
  11. X-Newsreader: WinVN 0.99.2
  12.  
  13. In article <3112841B.5D2F@allaire.com>, jlund@allaire.com says...
  14. >
  15. >helicon wrote:
  16. >>> nIndex:= GetFieldsForTable(strpcopy(pcharBuiffer,'Test'),
  17. >>>    strpcopy(pcharBuiffer,''),
  18. >>>    strpcopy(pcharBuiffer,''),
  19. >>>    strpcopy(pcharBuiffer,'Employees'));
  20. >> 
  21. >> I think the problem is, that you use the same Buffer for 
  22. >> each parameter. 
  23. >
  24. >I wish that were the problem, but I'm afraid that's my clumsy 
  25. >typing. "pcharBuiffer" is a typo. I use a different variable 
  26. >for each buffer in the actual code.
  27. >
  28. >I should mention that I'm running using 32 bit flavors of Delphi (2.0 
  29. >beta), and Visual C++ 4.0 on both Windows 95 and Windows NT.
  30. >
  31. >Thanks for responding, Andreas. 
  32. >
  33.  
  34. No problem :-)
  35.  
  36. I remember that you declare a method as external. Have you ever tried to call the function outside a class? 
  37.  
  38. For Instance:
  39.  
  40.   function _GetFieldsForTable ({...}) external {...}
  41.  
  42.   TODBCInformant.GetFieldsForTable ({...});
  43.   begin
  44.     Result := _GetFieldsForTable ({...});
  45.   end;
  46.  
  47. The problem could be that delphi use the implicit paremter "self" in each method. 
  48.  
  49. Bye and Good Luck
  50.  
  51. Andreas
  52.  
  53.  
  54.  
  55.